
include ../.env
export $(shell sed 's/=.*//' ../.env)

FLINK_IMAGE_NAME=docker.io/wzfei012/hadoop-devel:${HADOOP_VERSION}

DOCKERFILE=Dockerfile

PUSH=false

hadoop:
	cd ./build && docker build -t ${FLINK_IMAGE_NAME}  --build-arg HADOOP_VERSION=${HADOOP_VERSION} -f ${DOCKERFILE} .
ifeq (${PUSH},true)
	docker push ${FLINK_IMAGE_NAME}
endif

.PHONY: compose
compose:
	cd compose && docker compose up -d

.PHONY: compose-clean
compose-clean:
	cd compose && docker compose down